package com.freedy.concurrent.JMM.pattrens;

import java.lang.reflect.Constructor;

/**
 * @author Freedy
 * @date 2021/4/23 18:08
 */
public class Test {
    public static void main(String[] args) throws Exception {
        Class<? extends SingleTonEnum> aClass = SingleTonEnum.SingleTon.getClass();
        SingleTonEnum tonEnum = aClass.getDeclaredConstructor().newInstance();
        System.out.println(tonEnum.name());
    }

}
